package cn.luyifushi.sys.controller;

import cn.luyifushi.sys.service.UserService;
import cn.luyifushi.utils.Result;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @author sword-l
 * @version 1.0.0
 * @title UserController
 * @description
 **/
@RestController
@RequestMapping("/api/user")
public class UserController {
    @Resource
    private UserService userService;

    /**
     * 查询所有用户列表
     * @return
     */
    @GetMapping("/listAll")
    public Result listAll(){
        return Result.ok(userService.list());
    }

}
